<?php

namespace app\validate;

use think\Validate;

class Pay extends Validate {
    protected $rule = [
        'appid'   => 'require',
        'token'   => 'require',
        'time'    => 'require|number',
        'user_id' => 'require|number',
    ];

    protected $message = [
        'appid'           => 'appid字段不能为空',
        'token'           => 'token字段不能为空',
        'time.require'    => 'time字段不能为空',
        'time.number'     => 'time字段必须为数字',
        'user_id.require' => 'user_id字段不能为空',
        'user_id.number'  => 'user_id字段必须为数字',
    ];
}